package com.ruoyi.web.controller.system;

import java.util.ArrayList;
import java.util.List;

import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.supervise.domain.ConstructionPermit;

/**
 * @ClassName: SysApprovalController
 * @Description: 系统基础模块，审批管理接口
 * @Author wtj
 * @DateTime 2020-10-20 10:03:07
 */
@Controller
@RequestMapping("/system/approadmin")
public class SysApprovalController extends BaseController {
	private String prefix = "system/approval";
	
	/**
	 * @Title: approval
	 * @Description: 跳转到审批管理页面
	 * @Author wtj
	 * @DateTime 2020-10-20 10:03:00
	 * @return
	 */
	@RequiresPermissions("system:approadmin:view")
	@GetMapping()
	public String approval()
	{
	    return prefix + "/approval";
	}
	
	/**
	 * @Title: list
	 * @Description: 审批管理页面获取数据
	 * @Author wtj
	 * @DateTime 2020-10-20 10:03:50
	 * @return
	 */
	@RequiresPermissions("system:approadmin:list")
    @PostMapping("/list")
    @ResponseBody
    public TableDataInfo list()
    {
    	List<ConstructionPermit> constructionPermitList = new ArrayList<ConstructionPermit>();
    	return getDataTable(constructionPermitList);
    }

}
